#include <54func.h>
int main(int argc,char *argv[])
{
    // ./9_fileno.c  文件流和文件对象的关系
    ARGS_CHECK(argc,2);
    FILE *fp = fopen(argv[1],"r+");
    ERROR_CHECK(fp,NULL,"fopen");

    //fileno(fp):根据文件流返回文件描述符
    ssize_t sret = write(fileno(fp),"hello",5);
    printf("sret = %ld\n",sret);

    fclose(fp);
    return 0;
}
